﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage" %>
<%@ Import Namespace="volva.Models" %>

<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server">
    
    <table>
    <tr>
        <th>Nafn</th>
        <th>Lýsing</th>
    </tr>
    <%
        List<Station> stations = ViewData["stations"] as List<Station>;
        foreach (Station station in stations)
        {
            Response.Write( "<tr>" + 
                            "<td><a href='/Station/Details/" + station.id + "'>" + station.name + "</a></td>" +
                            "<td>" + station.description + "</td>" + 
                            "</th>");
        }
         %>
    </table>

</asp:Content>
